<!--
*Author：jxx
 *Contact：283591387@qq.com
 *代码由框架生成,任何更改都可能导致被代码生成器覆盖
 *业务请在@/extension/inventoryinfo/q_warehouse_add_allot_mxcx/q_warehouse_add_allot_mxcx.js此处编写
 -->
<template>
    <view-grid ref="grid"
               :columns="columns"
               :detail="detail"
               :editFormFields="editFormFields"
               :editFormOptions="editFormOptions"
               :searchFormFields="searchFormFields"
               :searchFormOptions="searchFormOptions"
               :table="table"
               :extend="extend">
    </view-grid>
</template>
<script>
    import extend from "@/extension/inventoryinfo/q_warehouse_add_allot_mxcx/q_warehouse_add_allot_mxcx.js";
    import { ref, defineComponent } from "vue";
    export default defineComponent({
        setup() {
            const table = ref({
                key: 'ID',
                footer: "Foots",
                cnName: '加价调拨明细查询',
                name: 'q_warehouse_add_allot_mxcx/q_warehouse_add_allot_mxcx',
                url: "/q_warehouse_add_allot_mxcx/",
                sortName: "审核时间"
            });
            const editFormFields = ref({});
            const editFormOptions = ref([]);
            const searchFormFields = ref({"单号":"","调出机构":"","调入机构":"","商品编码":"","商品名称":"","审核时间":""});
            const searchFormOptions = ref([[{"title":"单号","field":"单号","type":"like"},{"dataKey":"一级仓库","data":[],"title":"调出机构","field":"调出机构","type":"select"},{"dataKey":"一级仓库","data":[],"title":"调入机构","field":"调入机构","type":"select"}],[{"title":"商品编码","field":"商品编码","type":"like"},{"title":"商品名称","field":"商品名称","type":"like"},{"title":"审核时间","field":"审核时间","type":"datetime"}]]);
            const columns = ref([{field:'ID',title:'ID',type:'guid',width:110,hidden:true,require:true,align:'left'},
                       {field:'单号',title:'单号',type:'string',width:120,align:'left',sort:true},
                       {field:'调出机构',title:'调出机构',type:'string',bind:{ key:'一级仓库',data:[]},width:120,require:true,align:'left'},
                       {field:'调入机构',title:'调入机构',type:'string',bind:{ key:'一级仓库',data:[]},width:120,require:true,align:'left'},
                       {field:'税率',title:'税率',type:'decimal',width:110,require:true,align:'left'},
                       {field:'商品编码',title:'商品编码',type:'string',width:110,align:'left'},
                       {field:'商品名称',title:'商品名称',type:'string',width:220,align:'left'},
                       {field:'数量',title:'数量',type:'float',width:110,require:true,align:'left'},
                       {field:'调出成本金额',title:'调出成本金额',type:'float',width:110,align:'left'},
                       {field:'调出无税成本金额',title:'调出无税成本',type:'float',width:110,align:'left'},
                       {field:'调入金额',title:'调入金额',type:'float',width:110,align:'left'},
                       {field:'调入无税金额',title:'调入无税金额',type:'float',width:110,align:'left'},
                       {field:'毛利',title:'毛利',type:'float',width:110,align:'left'},
                       {field:'无税毛利',title:'无税毛利',type:'float',width:110,align:'left'},
                       {field:'审核状态',title:'审核状态',type:'int',bind:{ key:'audit',data:[]},width:110,align:'left'},
                       {field:'审核时间',title:'审核时间',type:'datetime',width:150,align:'left',sort:true}]);
            const detail = ref({
                cnName: "#detailCnName",
                table: "#detailTable",
                columns: [],
                sortName: "",
                key: ""
            });
            return {
                table,
                extend,
                editFormFields,
                editFormOptions,
                searchFormFields,
                searchFormOptions,
                columns,
                detail,
            };
        },
    });
</script>
